package com.neuedu.controller;
import com.neuedu.pojo.Result;
import com.neuedu.pojo.TAdministrator;
import com.neuedu.service.ITAdministratorService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author zhangsan
 * @since 2024-06-16
 */
@RestController
@RequestMapping("/administrator")
public class TAdministratorController {
    @Autowired
    ITAdministratorService administratorService;
    @GetMapping("/query/{adminno}")
    public Result findByAdminno(@PathVariable("adminno")String adminno){
        return administratorService.findByAdminno(adminno);
    }
    @PostMapping("/mod")
    public Result modAdmin(@RequestBody TAdministrator administrator){
        return administratorService.modAdmin(administrator);
    }
}
